﻿<?php
session_start();
header("content-type:text/html;charset=utf-8");
define("HOST","localhost");
define("USER","root");
define("PASS","");
define("DB","product");
define("CHAR","set names utf8");
//1连接数据库
$link=mysqli_connect(HOST,USER,PASS);
mysqli_select_db($link,DB);
mysqli_query($link,CHAR);
function msg($tip,$url)
{
	echo "<script type='text/javascript'>alert('$tip');location.href='$url';</script>";
}
?>